﻿''' <summary>
''' Leilão de oferta
''' </summary>
''' <remarks></remarks>
<Serializable()> _
Public Class Leilao

    Private _id As Nullable(Of Long)
    Public Overridable Property Id() As Nullable(Of Long)
        Get
            Return _id
        End Get
        Set(ByVal value As Nullable(Of Long))
            _id = value
        End Set
    End Property

    'Private _peca As Peca
    'Public Overridable Property Peca() As Peca
    '    Get
    '        Return _peca
    '    End Get
    '    Set(ByVal value As Peca)
    '        _peca = value
    '    End Set
    'End Property

    Private _lote As Lote
    Public Overridable Property Lote() As Lote
        Get
            Return _lote
        End Get
        Set(ByVal value As Lote)
            _lote = value
        End Set
    End Property

    Private _regra As RegraLeilao
    Public Overridable Property Regra() As RegraLeilao
        Get
            Return _regra
        End Get
        Set(ByVal value As RegraLeilao)
            _regra = value
        End Set
    End Property

    Private _ativo As Boolean
    Public Overridable Property Ativo() As Boolean
        Get
            Return _ativo
        End Get
        Set(ByVal value As Boolean)
            _ativo = value
        End Set
    End Property

    Private _autor As Usuario
    ''' <summary>
    ''' Quem cadastrou o Leilão
    ''' </summary>
    ''' <value></value>
    ''' <returns></returns>
    ''' <remarks></remarks>
    Public Overridable Property Autor() As Usuario
        Get
            Return _autor
        End Get
        Set(ByVal value As Usuario)
            _autor = value
        End Set
    End Property


    Private _leiloeiro As Usuario
    ''' <summary>
    ''' Em geral o sistema de leilão é o agente/leiloeiro
    ''' </summary>
    ''' <value></value>
    ''' <returns></returns>
    ''' <remarks></remarks>
    Public Overridable Property Leiloeiro() As Usuario
        Get
            Return _leiloeiro
        End Get
        Set(ByVal value As Usuario)
            _leiloeiro = value
        End Set
    End Property

End Class
